package com.situ.mall.entity;

import java.util.Date;

public class Cart {
	private Integer id;

	private Integer userId;

	private Integer productId;

	private Integer quantity;

	private Integer checked;

	private Date createTime;

	private Date updateTime;

	private Product product;

	public Product getProduct() {
		return product;
	}

	public void setProduct(Product product) {
		this.product = product;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Integer getUserId() {
		return userId;
	}

	public void setUserId(Integer userId) {
		this.userId = userId;
	}

	public Integer getProductId() {
		return productId;
	}

	public void setProductId(Integer productId) {
		this.productId = productId;
	}

	public Integer getQuantity() {
		return quantity;
	}

	public void setQuantity(Integer quantity) {
		this.quantity = quantity;
	}

	public Integer getChecked() {
		return checked;
	}

	public void setChecked(Integer checked) {
		this.checked = checked;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	@Override
	public String toString() {
		return "Cart [id=" + id + ", userId=" + userId + ", productId=" + productId + ", quantity=" + quantity
				+ ", checked=" + checked + ", createTime=" + createTime + ", updateTime=" + updateTime + ", product="
				+ product + "]";
	}

	/*
	 * @Override public String toString() { StringBuilder sb = new StringBuilder();
	 * sb.append(getClass().getSimpleName()); sb.append(" [");
	 * sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id);
	 * sb.append(", userId=").append(userId);
	 * sb.append(", productId=").append(productId);
	 * sb.append(", quantity=").append(quantity);
	 * sb.append(", checked=").append(checked);
	 * sb.append(", createTime=").append(createTime);
	 * sb.append(", updateTime=").append(updateTime); sb.append("]");
	 	return sb.toString();
	 	S}
	 */
	
}